<?php 
if(KT!='KhiThe') exit;
class support_controller extends support_model{
	
	public function __construct(){
		
		global $lang;
		
		$lang['url_base'] = url_base;	
		$this->path_cur = dirname(__FILE__);	
		parent::__construct();
		parent::addObject('khithe_template');
		parent::addObject('khithe_request');
		parent::addObject('khithe_string');
		parent::addObject('khithe_images');
		
		$this->lang = $lang;
	}
	public function index()
	{
		$strSupport = '';
		$arrSupport = parent::get_support(0);
		if($arrSupport>0){
			foreach ($arrSupport as $row_Support)
			{							
				$strSupport .='<div class="content_Support text_center">';
								if($row_Support['Kind']=='yahoo'){
									$strSupport .='<a style="text-decoration: none;" href="ymsgr:sendim?'.$row_Support['Nick'].'">
										<img src="http://opi.yahoo.com/online?u='.$row_Support['Nick'].'&m=g&t=14&l=us" border="0" complete="complete"/>
									</a><br />
									<h5><img src="{url_base}templates/publics/defaults/images/phone_icon.png" /> '.$row_Support['Fullname'].'</h5>
									';
								}else if($row_Support['Kind']=='skype'){
									$strSupport .='<script type="text/javascript" src="http://download.skype.com/share/skypebuttons/js/skypeCheck.js"></script>
                                    <br />
									<a style="text-decoration: none;" href="skype:'.$row_Support['Nick'].'?call">
                                    	<img src="http://mystatus.skype.com/bigclassic/'.$row_Support['Nick'].'" style="border: none;" width="124" height="52" alt="Skype Me™!" />
                                    </a><br />
									<h5><img src="{url_base}templates/publics/defaults/images/phone_icon.png" /> '.$row_Support['Fullname'].'</h5>
									';
								}
				$strSupport .='</div>';						
			}
		}
		$this->lang['content_support'] = $strSupport;
		$strModule = parent::khithe_display_template(dirname(__FILE__).'/support');
		return $strModule = parent::khithe_assign($strModule, $this->lang);
	}
	


}
?>